package com.cqh.recruit.utils;

import com.cqh.recruit.pojo.entity.Student;

/**
 * @author denghao
 * @date 2025/8/18
 */
public class StudentThreadLocal {

    //当前线程
    private static final ThreadLocal<Student> tl = new ThreadLocal<>();

    //绑定学生用户信息到当前线程
    public static void set(Student student) {
        tl.set(student);
    }

    //获取学生用户信息
    public static Student get() {
        return tl.get();
    }

    //删除学生用户信息
    public static void remove() {
        tl.remove();
    }

}
